var mongoose = require('mongoose');

//二级评论表(secondComment)

var secondCommentSchema = new mongoose.Schema({
    userid: {type: mongoose.SchemaTypes.ObjectId, ref: 'user_login',required: true}, //用户id
    commentid: {type: mongoose.SchemaTypes.ObjectId, ref: 'comment',required: true}, //评论id
    reply_user:{type: mongoose.SchemaTypes.ObjectId, ref: 'user_login',required: true},//回复用户id
    aeticletype:{type: String,required: true},//文章类型
    content: {type: String,required: true}, //评论内容
    release_time:{type: Date,default: new Date},//发布时间
})

module.exports = mongoose.model('secondComment', secondCommentSchema)